<template>
  <div class="mod-config">
    <table-view ref="view"
                :searchAttrs="searchAttrs"
                :primaryKey="primaryKey"
                :listApiName="listApiName"
                :deleteApiName="deleteApiName"
                :exportApiName="exportApiName"
                :saveAuthName="saveAuthName"
                :deleteAuthName="deleteAuthName"
                :showAttrs="showAttrs"
    >
    </table-view>
    <add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update>
  </div>
</template>


<script>
import tableView from '@/components/tableView'
import basicMixins from '@/utils/commonViewMixins'
import AddOrUpdate from './relatesprayheadinfo-add-or-update'

export default {
  mixins: [basicMixins],
  data() {
    return {
      primaryKey: 'id',
      listApiName: 'relateApi/listRelateSprayHeadInfo',
      deleteApiName: 'relateApi/deleteRelateSprayHeadInfo',
      exportApiName: 'relateApi/getRelateSprayHeadInfoExport',
      saveAuthName: 'relate:relatesprayheadinfo:save',
      deleteAuthName: 'relate:relatesprayheadinfo:delete',
      searchAttrs: {},
      showAttrs: {
        id: {
          label: 'id'
        },
        bottleSprayHeadNo: {
          label: '喷头型号'
        },
        spraySize: {
          label: '喷头规格'
        },
        sprayHeadDesc: {
          label: '规格描述'
        },
        sprayHeadType: {
          label: '喷头类别'
        },
        bottleOutDiameter: {
          label: '喷头口径'
        },
        sprayHeadColor: {
          label: '喷头颜色'
        },
        sprayHeadMaterial: {
          label: '喷头的材质'
        },
        sprayMethod: {
          label: '喷雾方式'
        },
        dischargeRate: {
          label: '出液量'
        },
        pipeRange: {
          label: '管长'
        },
        relateLevel: {
          label: '等级'
        },
        relateImageInfo: {
          label: '图片', type: 'image'
        },
        sprayAngle: {
          label: '喷雾角度'
        },
        remark: {
          label: '备注'
        },
        parentId: {
          label: '父级'
        }
      }
    }
  },
  components: {
    tableView,
    AddOrUpdate
  }
}
</script>
